package org.kgc.alanhealth.entity;

import java.io.Serializable;
import lombok.Data;

/**
 * 
 * @TableName hospital_symptom
 */
@Data
public class HospitalSymptom implements Serializable {
    /**
     * 药品id
     */
    private Integer drugsid;

    /**
     * 症状ID
     */
    private Integer symptomaticidid;

    /**
     * 药品描述
     */
    private String drugdescription;

    /**
     * 
     */
    private String picture;

    private static final long serialVersionUID = 1L;

    @Override
    public boolean equals(Object that) {
        if (this == that) {

        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        HospitalSymptom other = (HospitalSymptom) that;
        return (this.getDrugsid() == null ? other.getDrugsid() == null : this.getDrugsid().equals(other.getDrugsid()))
            && (this.getSymptomaticidid() == null ? other.getSymptomaticidid() == null : this.getSymptomaticidid().equals(other.getSymptomaticidid()))
            && (this.getDrugdescription() == null ? other.getDrugdescription() == null : this.getDrugdescription().equals(other.getDrugdescription()))
            && (this.getPicture() == null ? other.getPicture() == null : this.getPicture().equals(other.getPicture()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getDrugsid() == null) ? 0 : getDrugsid().hashCode());
        result = prime * result + ((getSymptomaticidid() == null) ? 0 : getSymptomaticidid().hashCode());
        result = prime * result + ((getDrugdescription() == null) ? 0 : getDrugdescription().hashCode());
        result = prime * result + ((getPicture() == null) ? 0 : getPicture().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", drugsid=").append(drugsid);
        sb.append(", symptomaticidid=").append(symptomaticidid);
        sb.append(", drugdescription=").append(drugdescription);
        sb.append(", picture=").append(picture);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}